package cola0502.project.hellospringbootcola0502.listener;

import cola0502.project.hellospringbootcola0502.event.ColaEvent;
import lombok.extern.slf4j.Slf4j;
import org.springframework.context.ApplicationListener;
import org.springframework.stereotype.Component;

@Component
@Slf4j
public class ColaListener implements ApplicationListener<ColaEvent> {
    @Override
    public void onApplicationEvent(ColaEvent event) {
        log.info("ColaEvent was published:  {}", event.getSource());
    }
}
